import {createApp} from 'vue'
import App from './App.vue'

import router from './router'
import store from './store'
import * as IconsVue from '@element-plus/icons-vue'

import 'vite-plugin-svg-icons/register'
import '@/assets/css/common.css'

const app = createApp(App)
app.use(router)
app.use(store)

const modules = import.meta.globEager('./components/**/index.ts')

for (const path in modules) {
    app.use(modules[path].default)
}

let k: keyof typeof IconsVue

for (k in IconsVue) {
    app.component(k, IconsVue[k])
}

app.mount('#app')


